package com.dyc.Utils;

import android.content.Context;
import android.content.SharedPreferences;

public class SharedUtils {

    private static final String FILE_NAME = "dianping";

    private static final String MODE_NAME = "welcome";

    public static boolean getWelcomeBoolean(Context context) {
        return context.getSharedPreferences(FILE_NAME, Context.MODE_PRIVATE).getBoolean(MODE_NAME, false);
    }

    public static void putWelcomeBoolean(Context context, boolean isFirst) {
        SharedPreferences.Editor edit = context.getSharedPreferences(FILE_NAME, Context.MODE_PRIVATE).edit();
        edit.putBoolean(MODE_NAME, isFirst);
        edit.commit();
    }

}
